package com.ssy.lingxi.logistics.model.response;

import lombok.Data;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.List;

/**
 * 运费模板返回实体类
 *
 * @author yzc
 * @version 2.0.0
 * @date 2020/7/14
 */
@Data
public class FreightTemplateResponse implements Serializable {

    private static final long serialVersionUID = 6292494919131453663L;

    /**
     * 主键id
     */
    private Long id;

    /**
     * 模板名称
     */
    private String name;

    /**
     * 计价方式 1-按重量
     */
    private Integer pricingMode;

    /**
     * 运送方式 1-快递
     */
    private Integer transportMode;

    /**
     * 重量(KG)
     */
    private Double weight;

    /**
     * 价格(元)
     */
    private BigDecimal price;

    /**
     * 每增加重量(KG)
     */
    private Double incrementWeight;

    /**
     * 每增加价格(元)
     */
    private BigDecimal incrementPrice;

    /**
     * 运费说明
     */
    private String explain;

    /**
     * 运费说明
     */
    private List<FreightTemplateDesignateResponse> designateList;

    @Data
    public static class FreightTemplateDesignateResponse implements Serializable {

        private static final long serialVersionUID = -573947766935956628L;

        /**
         * 主键id
         */
        private Long id;

        /**
         * 运费模板id
         */
        private Long freightTemplateId;

        /**
         * 地区编号
         */
        private List<String> areaIds;

        /**
         * 重量(KG)
         */
        private Double weight;

        /**
         * 价格(元)
         */
        private BigDecimal price;

        /**
         * 每增加重量(KG)
         */
        private Double incrementWeight;

        /**
         * 每增加价格(元)
         */
        private BigDecimal incrementPrice;
    }
}
